﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using OgilvyOne.Utility;
using OgilvyOne.Model;

namespace OgilvyOne.IDAL
{
    public interface IVicoRegInfo
    {
        int Add(VicoRegInfoModel model);
        bool IsExists(string email);
        PageTools Query(VicoRegInfoModel q, int pagenum, int pagesize);
        bool Del(string ids);

        VicoRegInfoModel GetModel(int id);
        DataSet QueryImp(VicoRegInfoModel q);
        /// <summary>
        /// 获取最大ID
        /// </summary>
        /// <returns></returns>
        int GetMaxID();
        /// <summary>
        /// 返回注册日期
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        string GetAddTime(int id);
        /// <summary>
        ///CCC接口返回状态标识更新,包括resultCode、resultDes、resultDetail 
        /// </summary>
        /// <param name="id"></param>
        /// <param name="resultCode"></param>
        /// <param name="resultDesc"></param>
        /// <param name="resultDetail"></param>
        /// <returns></returns>
        int UpdateSendResultStatus(int id, string resultCode, string resultDesc, string resultDetail);

        /// <summary>
        ///更新返回错误状态信息，如avato webservices不可用，或网络原因造成的错误 
        /// </summary>
        /// <param name="id"></param>
        /// <param name="errMsg"></param>
        /// <returns></returns>
        int UpdateSendError(int id, string errMsg);

        /// <summary>
        /// 更新avato webservice 返回状态信息时间
        /// </summary>
        /// <param name="id"></param>
        /// <param name="receiviTime"></param>
        /// <returns></returns>
        int UpdateReceive_CCC_Time(int id, DateTime receiviTime);
    }
}
